Implement RGB to Hex Color Converter #8
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implement RGB to Hex Color Converter
Description
Task
Implement RGB to Hex Converter
Acceptance Criteria
Summary of Work
Overview
This pull request implements a robust RGB to Hex color converter function with comprehensive error handling and testing.
Changes Made
src/rgb_to_hex.pywithrgb_to_hex()functiontests/test_rgb_to_hex.pyImplementation Details
Function Capabilities
Error Handling
TypeErrorfor non-integer inputsValueErrorfor out-of-range color valuesTesting Approach
Implemented 5 test cases covering:
Test Results
Acceptance Criteria
✓ Correctly converts RGB to Hex
✓ Handles input validation
✓ Provides clear error messages
✓ Comprehensive test coverage
Notes
Changes Made
Tests
Signatures
Staking Key
AEghvdqmRtc3fjKXfNTMJJ6WshksgWuJ9YBExgsZu8cN: JJFqysiKLyQAf9Jjkj2A2eAKuFuWXPPR5mdQwfdH5GaXzbCJtkkyzNveCPYfNqZyuXoqiW85G4r66Ka324mbsPj77CYE6pHxHUhdCd123S4RD6end82tTN9gwvsucLMvGgoxCtx4MxCcjbdw38kAVB5pgpLXmycxqPYkiBZUkep7tJWZNKJsTgzMkNzGdFP7fdtmz9ctvdHByFQ6LTboxvVFJq92GnrkD9WybsGVtkg1WqWZtyiwYrbKdePL7cmQp1Ds6i7f9nuYeLxUVQ27SaXJuHY1FCn7Uodp8s6VmpxHEV2b8JB11kW63WznkiNbhxgTfq77VM3PocgapX27q5Ev2rsMbn9vDD69tLgzFyxevvdY3qE6smwCj3KtiMH6XVu383o8xz9nv1Vcs1ZC4BrmMqwUwNWAJ8
Public Key
AwXAtX7tMhL4JyB8NfXdsrqc1UifaMyap3c9bpN9RMse: AM6E1LD1F3nadHoSkqFKFfqx3HKrBsDCwHQwAU3nF5UmyS8PvCc69aCt37BQLcpycKbVFSJCiZWN8MNDH2NhNoCrvjxMkL6CBq9aZVcv7w9ohBCXqPztFgZNb96Tnhx4tis4MmhpKdxZ5GHWPvnBm6nm7z8nmaM2htexivmYaGCimKVfpEM93CcXG2SAnQ8uogjqNrgPrw4XTHH6nz8P7TEnU7tbzdx41cyiQPcjMp6y7d2sde9iebEzFVEadx6RksXxVoBLYDyKbLJ82hm3ppTD5SQRGkHPVSRsDABBubVtzGVBkbEee8YhfEac4YHNCv6okKoc8bT8VvtR9FUaH9k6hD79Gx2W5brJHBYQWqq7bop7yPJCLSEgTLK8ADwkaWmaFkXuGrjs7R4zUZ7MFD3Z4Kw2N6MYrx